﻿using System;
using System.Collections.Generic;


namespace EnterpriseLibraryGeneric.DataAccess
{
    class DataAccessComponentFactory
    {
        public static IDataAccessComponentManager GetFactory(string componentDataProvider, string dataProvider)
        {
            //Selecciona el DAO Factory a aplicar segun parametro
            switch (componentDataProvider)
            {
                case "DataAccessManager":
                    { 
                        return new DataAccessManager(dataProvider);
                    }
                case "DataAccessAplicationBlock":
                    {
                        return new DataAccessApplicationBlock(dataProvider);
                    }
                default: return new DataAccessApplicationBlock(dataProvider);
            }
        }
    }
}
